package com.rmkj.trade.match.core;

import java.util.Iterator;
import java.util.List;

/**
 * Created by Administrator on 2019/1/8.
 * 存储交易
 */
public interface OrderStore {

	boolean put(Order order);

	void putReal();

	boolean update(OrderPairs orderPairs);

	boolean remove(Order order);

	Order firstSell();

	Order firstBuy();

	/**
	 * 按价格从低到高
	 * @return
	 */
	Iterator<Order> sellOrders();

	/**
	 * 按价格从高到低
	 * @return
	 */
	Iterator<Order> buyOrders();

	Iterator<OrderPairs> orderPairs();

}
